package name.marz.to.go.btree.node;

import static org.junit.Assert.*;

import org.junit.After;
import org.junit.Before;
import org.junit.Test;

public class BTreeTest {
	@Before
	public void setUp() throws Exception {
	}

	@After
	public void tearDown() throws Exception {
	}

	@Test
	public void testSearch() {
		fail("Not yet implemented"); // TODO
	}

	@Test
	public void testInsert() {
		BTree<String> tree;
		Node root = NodeFactory.createNode(ArrayNode.class.getName(), 2);
		tree = new BTree<String>(root);
		
		tree.insert(new Key(1), "test01");
		
		assertEquals(root.getKey(0).getValue(),1);
		assertEquals(root.getPointer(0),"test01");
	}

}
